package org.jeecg.modules.api.xxApi.validate;

import javax.validation.Constraint;
import javax.validation.Payload;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

/**
 * 小数位数控制
 */
@Target({ElementType.FIELD, ElementType.METHOD})
@Retention(RetentionPolicy.RUNTIME)
@Constraint(validatedBy=DecimalLengthValidator.class)
public @interface DecimalLength {

    int max() default 2;

    String message() default"小数格式不正确";

    Class<?>[] groups() default {};

    Class<? extends Payload>[] payload() default {};

}
